In an electronic parts packaging line for fabricating packaged substrates in which electronic parts are packaged on substrates, a screen printing apparatus for printing an electronic parts joining paste on a substrate is connected to an upstream side of an electronic parts mounting apparatus for mounting electronic parts such as semiconductor devices on a substrate. Conventionally, as a type of substrate on which electronic parts are packaged, a so-called cavity substrate has been known in which electrode patterns are formed on both an upper surface of a substrate and a bottom surface of a recess portion which is opened in the upper surface of the substrate and has been in use in various types of equipment as a light, high density substrate (Patent Document 1). In a screen printing in which an electronic parts joining paste is printed on such a cavity substrate as an object, a three-dimensional screen mask is used which has a flat plate portion which is brought into contact with an upper surface of the substrate and a fitting portion which is formed to project downwards from the flat plate portion so as to fit in a recess portion in the substrate. By using the three-dimensional screen mask, the paste can be printed simultaneously on both the upper surface of the substrate and the bottom surface of the recess portion therein.